#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "prototypes.h"

void afficheCarte(int tab[HAUTEUR_CARTE][LARGEUR_CARTE], Personnage* perso1, Personnage* perso2, Personnage* panda)
{
	int i = 0, j = 0, c = ' ';

	for(i = 0 ; i < HAUTEUR_CARTE ; i++)
	{

		for(j = 0 ; j < LARGEUR_CARTE ; j++)
		{

			c = tab[i][j];
			if(tab[i][j] == 'M') c = 219;

			if(perso1->invisible == 0 && perso1->x == j && perso1->y == i) c = perso1->caractere;
			if(perso2->invisible == 0 && perso2->x == j && perso2->y == i) c = perso2->caractere;
			if(panda->invisible == 0 && panda->x == j && panda->y == i) c = panda->caractere;

			printf("%c", c);
		}

		printf("\n");
	}

}



